var cookieParse = require('./cookieParse');
module.exports = function (req) {
    var cookie = cookieParse(req);
    if(session[cookie.sessionId]) {
        req.session = session[cookie.sessionId];
        return true;
    }else{
        return false;
    }
}